package com.ys.nms.module.business.controller.admin.customOid.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import cn.idev.excel.annotation.*;

@Schema(description = "管理后台 - 自定义OID Response VO")
@Data
@ExcelIgnoreUnannotated
public class CustomOidRespVO {

    @Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "9495")
    @ExcelProperty("ID")
    private Integer customoidId;

    @Schema(description = "设备ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "17456")
    @ExcelProperty("设备ID")
    private Integer deviceId;

    @Schema(description = "描述")
    @ExcelProperty("描述")
    private String customoidDescr;

    @Schema(description = "0未删除1删除", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("0未删除1删除")
    private Integer customoidDeleted;

    @Schema(description = "当前采集到的 OID 值，经过乘数/除数处理后的实际值")
    @ExcelProperty("当前采集到的 OID 值，经过乘数/除数处理后的实际值")
    private Double customoidCurrent;

    @Schema(description = "上一次采集到的 OID 值")
    @ExcelProperty("上一次采集到的 OID 值")
    private Double customoidPrev;

    @Schema(description = "OID", example = "22851")
    @ExcelProperty("OID")
    private String customoidOid;

    @Schema(description = "数据类型，常见值包括：	• GAUGE	（瞬时值，如温度）	• COUNTER	（计数器，如流量）	• DERIVE	（差值）	• ABSOLUTE	（绝对值）", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @ExcelProperty("数据类型，常见值包括：	• GAUGE	（瞬时值，如温度）	• COUNTER	（计数器，如流量）	• DERIVE	（差值）	• ABSOLUTE	（绝对值）")
    private String customoidDatatype;

    @Schema(description = "单位标识，如 %	、°C	、RPM")
    @ExcelProperty("单位标识，如 %	、°C	、RPM")
    private String customoidUnit;

    @Schema(description = "采集值除以此数得到实际值", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("采集值除以此数得到实际值")
    private Integer customoidDivisor;

    @Schema(description = "采集值乘以此数得到实际值", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("采集值乘以此数得到实际值")
    private Integer customoidMultiplier;

    @Schema(description = "告警上限阈值。当值超过此数且 customoid_alert=1	 时触发告警。")
    @ExcelProperty("告警上限阈值。当值超过此数且 customoid_alert=1	 时触发告警。")
    private Double customoidLimit;

    @Schema(description = "警告上限阈值。超过此值但未达 limit	 时触发警告。")
    @ExcelProperty("警告上限阈值。超过此值但未达 limit	 时触发警告。")
    private Double customoidLimitWarn;

    @Schema(description = "告警下限阈值。当值低于此数且 customoid_alert=1	 时触发告警。")
    @ExcelProperty("告警下限阈值。当值低于此数且 customoid_alert=1	 时触发告警。")
    private Double customoidLimitLow;

    @Schema(description = "警告下限阈值。低于此值但未达 limit_low	 时触发警告。")
    @ExcelProperty("警告下限阈值。低于此值但未达 limit_low	 时触发警告。")
    private Double customoidLimitLowWarn;

    @Schema(description = "是否启用告警：0=不启用，1=启用。", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("是否启用告警：0=不启用，1=启用。")
    private Integer customoidAlert;

    @Schema(description = "当前值是否通过阈值检查：0=未通过（告警或警告），1=通过（正常", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("当前值是否通过阈值检查：0=未通过（告警或警告），1=通过（正常")
    private Integer customoidPassed;

    @Schema(description = "最后更新时间戳", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("最后更新时间戳")
    private LocalDateTime lastupdate;

    @Schema(description = "用户自定义处理函数名")
    @ExcelProperty("用户自定义处理函数名")
    private String userFunc;

}